home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
CD ROM Paradise Collection 4
/
CD ROM Paradise Collection 4 1995 Nov.iso
/
dskutil
/
msort112.zip
/
MSORT.DOC
< prev
next >
Wrap
Text File
|
1995-01-21
|
16KB
|
388 lines
MSORT -- Master Sort Program
SSORT -- Speedy Sort Program
Version 1.12
This document and the associated software are
Copyright 1994 by Martin Katz, Ph.D. all rights reserved.
PURPOSE
MSORT and SSORT are superior text file sorting programs for DOS. MSORT and
SSORT are faster, easier to use and more powerful than the sort program
included with MS-DOS or PC-DOS. In addition, while DOS sort is limited to
small files, MSORT can sort huge files.
MSORT and SSORT allow you to sort files either alphabetically or numerically. You can also define the columns that define the sorting keys, sort in
reverse, ignore spaces while sorting, and treat upper and lower case as the
same, and much more. If you wish, MSORT will remove duplicate lines and/or
blank lines.
These are fully functional programs with no shareware reminders. MSORT and
SSORT are shareware and your support is necessary to continue development
of this product. If you find this software useful, you are obligated to
register it. Please See the LICENSE section below and the registration form
at the end of this file for more details. Please return the registration
form, even if you decide not to pay for this package.
Your comments and suggestions are welcome. Please email comments to me at
"katz@titan.fullerton.edu" I can also be reached by sending a message to
"Martin Katz" on the RIME Shareware conference (private is preferred).
LICENSE
Neither the author, nor the distributors of these programs assume
responsibility for any loss related directly or indirectly to the use of
this product. No warranty is implied or stated, including any warranty of
suitability for use. Use this product at your own risk.
If you have problems or questions, please send me a message via e-mail at
katz@titan.fullerton.edu (I can also be reached on the RIME shareware
conference). Please include the program name, version number (shown at the
top of this file), a specific explanation of your problem, and your e-mail
address.
These programs may be freely distributed provided that they are not
changed, this file is included, and that no charge is made for this
software, except for media costs (limited to less than $10).
All distribution must include the following files:
MSORT.DOC,
MSORT.EXE, and
SSORT.EXE.
The following additional files are included for convenience:
FILE_ID.DIZ,
HISTORY,
README,
REGISTER.FRM,
SORTTAGS.BAT, and
TESTFILE.COM.
USING SSORT and MSORT
You use the programs SSORT and MSORT in the same way. SSORT is faster, but
cannot sort large files (the data must all fit in memory). If SSORT cannot
sort your file, please use MSORT. This section will show SSORT in the
examples, but you can use MSORT the same way.
SSORT and MSORT assume that each line in your file ends with a line-feed
character (carriage-returns are ignored). Formatting and control characters
used in word processors should not be included in the input file (they are
just treated as characters to sort).
The simplest way to sort two files is
SSORT (input file) (output file)
where (input file) and (output file) are file names. For example, to sort
the file PHONE.BOK and output to PHONE.SRT you would type
SSORT PHONE.BOK PHONE.SRT
SSORT can also take its input from the DOS standard input and output to DOS
standard output (this is the manner required by the standard DOS sort
program). For example:
SSORT < PHONE.BOK > PHONE.SRT
WARNING: If you use redirection, the input and output files must always
be different. Otherwise, the input file will be destroyed. Use
of the DOS SHARE program (or MS Windows) will prevent this
destruction of data.
OPTIONS
Options may begin with either a hyphen or a slash, and they may be either
upper or lower case. They are shown with hyphens below for ease of reading.
CONTROLLING THE SORTING ORDER
You can change the sorting order by using any of the following options
before the file names:
-c Case independent. Treat all letters as if they are upper case.
Without this option, upper case comes before lower case.
-# Only letters will be used when comparing lines.
-a Only letters and digits will be used when comparing lines.
-d Only digits will be used when comparing lines.
-w Ignores spaces, tabs, etc. (Whitespace).
-t Ignore common short words (slow process). This includes:
a, an, am, are, do, if, is, I, me, my, that, the, this, we, you
-n Sort Numerically. This means that leading a leading plus sign,
leading spaces, or leading zeroes will be ignored. If the number
begins with a negative sign, it will be considered negative. If
one of the remaining numbers is longer than the other, it is
considered larger than the other.
-r Sort in Reverse order
-s Sort by line length (size).
+N (N is a decimal number) Ignore characters before text column N
when comparing lines to sort. The first text column is column 1.
-+N and /+N are the same as +N.
+N.M (N and M are decimal numbers) Defines a field to sort beginning at
column N, and M characters wide. You may define up to 10 fields
when sorting. Later fields are only checked if the lines are equal
in earlier fields. -+N.M and /+N.M are the same as +N.M
The sort order options (-# -a, -c, -d, -n, -r, -s,